package com.catchman.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.catchman.entity.SysPerm;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 权限 Mapper 接口
 * </p>
 *
 * @author catchman
 * @since 2019-04-29
 */
public interface SysPermDao extends BaseMapper<SysPerm> {

    List<SysPerm> getPermsByUserId(String userId);

    List<SysPerm> getPermsByRoleId(String roleId);

    void saveOrUpdate(@Param("perms") List<SysPerm> perms);
}
